import Vue from 'vue';
import Vuex from 'vuex';
import getters from './getters';
import app from './modules/app';
import permission from './modules/permission';
import settings from './modules/settings';
import txs from './modules/txs';
import user from './modules/user';

Vue.use(Vuex);

const store = new Vuex.Store({
  modules: {
    app,
    settings,
    permission,
    txs,
    user,
  },
  getters,
});

export default store;
// import Vue from 'vue'
// import Vuex from 'vuex'
// import txs from './modules/txs'
// import user from './modules/user'
// import app from './modules/app'
// import settings from './modules/settings'

// Vue.use(Vuex)

// export default new Vuex.Store({
//   state: {
//   },
//   mutations: {
//   },
//   getters:{
//     sidebar: state => state.app.sidebar,
//     device: state => state.app.device,
//     token: state => state.user.token,
//     avatar: state => state.user.avatar,
//     name: state => state.user.name
//   },
//   actions: {
//   },
//   modules: {
//     txs,
//     app,
//     settings,
//     user
//   }
// })
